12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640 |
- (() => {
- var exports = {};
- exports.id = 44279;
- exports.ids = [44279,64820];
- exports.modules = {
- /***/ 51809:
- /***/ ((module, __webpack_exports__, __webpack_require__) => {
- "use strict";
- __webpack_require__.a(module, async (__webpack_handle_async_dependencies__, __webpack_async_result__) => { try {
- __webpack_require__.r(__webpack_exports__);
- /* harmony export */ __webpack_require__.d(__webpack_exports__, {
- /* harmony export */ "default": () => (/* binding */ pageWrapperTemplate),
- /* harmony export */ "getServerSideProps": () => (/* binding */ getServerSideProps),
- /* harmony export */ "getStaticPaths": () => (/* binding */ getStaticPaths),
- /* harmony export */ "getStaticProps": () => (/* binding */ getStaticProps)
- /* harmony export */ });
- /* harmony import */ var _sentry_server_config_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(96270);
- /* harmony import */ var _sentry_nextjs__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(58097);
- /* harmony import */ var _sentry_nextjs__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_sentry_nextjs__WEBPACK_IMPORTED_MODULE_1__);
- /* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(20997);
- /* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_2__);
- /* harmony import */ var next_router__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(71853);
- /* harmony import */ var next_router__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(next_router__WEBPACK_IMPORTED_MODULE_3__);
- /* harmony import */ var next_translate_useTranslation__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(60866);
- /* harmony import */ var next_translate_useTranslation__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(next_translate_useTranslation__WEBPACK_IMPORTED_MODULE_4__);
- /* harmony import */ var _courses_module_scss__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(97523);
- /* harmony import */ var _courses_module_scss__WEBPACK_IMPORTED_MODULE_15___default = /*#__PURE__*/__webpack_require__.n(_courses_module_scss__WEBPACK_IMPORTED_MODULE_15__);
- /* harmony import */ var _components_Course_CourseDetails__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(84346);
- /* harmony import */ var _components_DataFetcher__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(12951);
- /* harmony import */ var _components_NextSeoWrapper__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(25869);
- /* harmony import */ var _components_PageContainer__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(9234);
- /* harmony import */ var _dls_Spinner_Spinner__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(7190);
- /* harmony import */ var _pages_index_module_scss__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(23848);
- /* harmony import */ var _pages_index_module_scss__WEBPACK_IMPORTED_MODULE_14___default = /*#__PURE__*/__webpack_require__.n(_pages_index_module_scss__WEBPACK_IMPORTED_MODULE_14__);
- /* harmony import */ var _utils_auth_api__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(37883);
- /* harmony import */ var _utils_auth_apiPaths__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(13830);
- /* harmony import */ var _utils_locale__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(24709);
- /* harmony import */ var _utils_navigation__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(57933);
- /* harmony import */ var _utils_staticPageGeneration__WEBPACK_IMPORTED_MODULE_16__ = __webpack_require__(45137);
- var __webpack_async_dependencies__ = __webpack_handle_async_dependencies__([_components_Course_CourseDetails__WEBPACK_IMPORTED_MODULE_5__, _components_DataFetcher__WEBPACK_IMPORTED_MODULE_6__, _utils_navigation__WEBPACK_IMPORTED_MODULE_13__]);
- ([_components_Course_CourseDetails__WEBPACK_IMPORTED_MODULE_5__, _components_DataFetcher__WEBPACK_IMPORTED_MODULE_6__, _utils_navigation__WEBPACK_IMPORTED_MODULE_13__] = __webpack_async_dependencies__.then ? (await __webpack_async_dependencies__)() : __webpack_async_dependencies__);
- const Loading = ()=>/*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_2__.jsx)("div", {
- className: (_pages_index_module_scss__WEBPACK_IMPORTED_MODULE_14___default().loadingContainer),
- children: /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_2__.jsx)(_dls_Spinner_Spinner__WEBPACK_IMPORTED_MODULE_9__/* ["default"] */ .Z, {})
- });
- const LearningPlanPage = ({ course })=>{
- const { lang , t } = next_translate_useTranslation__WEBPACK_IMPORTED_MODULE_4___default()("learn");
- const router = (0,next_router__WEBPACK_IMPORTED_MODULE_3__.useRouter)();
- const { slug } = router.query;
- const url = (0,_utils_navigation__WEBPACK_IMPORTED_MODULE_13__/* .getCourseNavigationUrl */ .ES)(course.slug);
- return /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_2__.jsxs)(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_2__.Fragment, {
- children: [
- /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_2__.jsx)(_components_NextSeoWrapper__WEBPACK_IMPORTED_MODULE_7__/* ["default"] */ .Z, {
- title: course.title,
- canonical: (0,_utils_navigation__WEBPACK_IMPORTED_MODULE_13__/* .getCanonicalUrl */ .Z2)(lang, url),
- description: course?.metaDescription || t("learning-plan-meta-desc"),
- languageAlternates: (0,_utils_locale__WEBPACK_IMPORTED_MODULE_12__/* .getLanguageAlternates */ .qc)(url)
- }),
- /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_2__.jsx)("div", {
- className: (_pages_index_module_scss__WEBPACK_IMPORTED_MODULE_14___default().pageContainer),
- children: /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_2__.jsx)("div", {
- className: (_courses_module_scss__WEBPACK_IMPORTED_MODULE_15___default().container),
- children: /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_2__.jsx)(_components_PageContainer__WEBPACK_IMPORTED_MODULE_8__/* ["default"] */ .Z, {
- children: /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_2__.jsx)(_components_DataFetcher__WEBPACK_IMPORTED_MODULE_6__/* ["default"] */ .Z, {
- loading: Loading,
- queryKey: (0,_utils_auth_apiPaths__WEBPACK_IMPORTED_MODULE_11__/* .makeGetCourseUrl */ .vp)(slug),
- fetcher: _utils_auth_api__WEBPACK_IMPORTED_MODULE_10__/* .privateFetcher */ .UK,
- render: (courseDetailsResponse)=>/*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_2__.jsx)(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_2__.Fragment, {
- children: /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_2__.jsx)(_components_Course_CourseDetails__WEBPACK_IMPORTED_MODULE_5__/* ["default"] */ .Z, {
- course: courseDetailsResponse
- })
- })
- })
- })
- })
- })
- ]
- });
- };
- const getStaticPaths = async ()=>({
- paths: [],
- fallback: "blocking"
- });
- const getStaticProps$1 = async ({ params })=>{
- try {
- const course = await (0,_utils_auth_api__WEBPACK_IMPORTED_MODULE_10__/* .getCourse */ .XR)(params.slug);
- return {
- props: {
- course
- },
- revalidate: _utils_staticPageGeneration__WEBPACK_IMPORTED_MODULE_16__/* .ONE_WEEK_REVALIDATION_PERIOD_SECONDS */ .Dp
- };
- } catch (error) {
- return {
- props: {
- hasError: true
- },
- revalidate: _utils_staticPageGeneration__WEBPACK_IMPORTED_MODULE_16__/* .REVALIDATION_PERIOD_ON_ERROR_SECONDS */ .eW
- };
- }
- };
- var serverComponentModule = /*#__PURE__*/Object.freeze({
- __proto__: null,
- getStaticPaths: getStaticPaths,
- getStaticProps: getStaticProps$1,
- 'default': LearningPlanPage
- });
- /*
- * This file is a template for the code which will be substituted when our webpack loader handles non-API files in the
- * `pages/` directory.
- *
- * We use `__SENTRY_WRAPPING_TARGET_FILE__.cjs` as a placeholder for the path to the file being wrapped. Because it's not a real package,
- * this causes both TS and ESLint to complain, hence the pragma comments below.
- */
- const userPageModule = serverComponentModule ;
- const pageComponent = userPageModule ? userPageModule.default : undefined;
- const origGetInitialProps = pageComponent ? pageComponent.getInitialProps : undefined;
- const origGetStaticProps = userPageModule ? userPageModule.getStaticProps : undefined;
- const origGetServerSideProps = userPageModule ? userPageModule.getServerSideProps : undefined;
- // eslint-disable-next-line @typescript-eslint/no-explicit-any
- const getInitialPropsWrappers = {
- '/_app': _sentry_nextjs__WEBPACK_IMPORTED_MODULE_1__.wrapAppGetInitialPropsWithSentry,
- '/_document': _sentry_nextjs__WEBPACK_IMPORTED_MODULE_1__.wrapDocumentGetInitialPropsWithSentry,
- '/_error': _sentry_nextjs__WEBPACK_IMPORTED_MODULE_1__.wrapErrorGetInitialPropsWithSentry,
- };
- const getInitialPropsWrapper = getInitialPropsWrappers['/learning-plans/[slug]'] || _sentry_nextjs__WEBPACK_IMPORTED_MODULE_1__.wrapGetInitialPropsWithSentry;
- if (pageComponent && typeof origGetInitialProps === 'function') {
- pageComponent.getInitialProps = getInitialPropsWrapper(origGetInitialProps) ;
- }
- const getStaticProps =
- typeof origGetStaticProps === 'function'
- ? _sentry_nextjs__WEBPACK_IMPORTED_MODULE_1__.wrapGetStaticPropsWithSentry(origGetStaticProps, '/learning-plans/[slug]')
- : undefined;
- const getServerSideProps =
- typeof origGetServerSideProps === 'function'
- ? _sentry_nextjs__WEBPACK_IMPORTED_MODULE_1__.wrapGetServerSidePropsWithSentry(origGetServerSideProps, '/learning-plans/[slug]')
- : undefined;
- const pageWrapperTemplate = pageComponent ? _sentry_nextjs__WEBPACK_IMPORTED_MODULE_1__.wrapPageComponentWithSentry(pageComponent ) : pageComponent;
- __webpack_async_result__();
- } catch(e) { __webpack_async_result__(e); } });
- /***/ }),
- /***/ 38264:
- /***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
- "use strict";
- /* harmony export */ __webpack_require__.d(__webpack_exports__, {
- /* harmony export */ "Z": () => (__WEBPACK_DEFAULT_EXPORT__)
- /* harmony export */ });
- /* harmony import */ var react__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(16689);
- /* harmony import */ var react__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_0__);
- var _path;
- function _extends() { return _extends = Object.assign ? Object.assign.bind() : function (n) { for (var e = 1; e < arguments.length; e++) { var t = arguments[e]; for (var r in t) ({}).hasOwnProperty.call(t, r) && (n[r] = t[r]); } return n; }, _extends.apply(null, arguments); }
- var SvgCollection = function SvgCollection(props) {
- return /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0__.createElement("svg", _extends({
- width: 24,
- height: 24,
- viewBox: "0 0 24 24",
- fill: "none",
- xmlns: "http://www.w3.org/2000/svg"
- }, props), _path || (_path = /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0__.createElement("path", {
- d: "M20.89 0H3.454C2.581 0 2 .581 2 1.453v20.344c0 .872.581 1.453 1.453 1.453h17.438c.872 0 1.453-.581 1.453-1.453V1.453C22.344.581 21.762 0 20.89 0ZM6.36 18.89c-.873 0-1.454-.58-1.454-1.453 0-.871.582-1.453 1.453-1.453.872 0 1.454.582 1.454 1.454 0 .871-.582 1.453-1.454 1.453Zm0-5.812c-.873 0-1.454-.581-1.454-1.453 0-.872.582-1.453 1.453-1.453.872 0 1.454.581 1.454 1.453 0 .872-.582 1.453-1.454 1.453Zm0-5.812c-.873 0-1.454-.582-1.454-1.454 0-.871.582-1.453 1.453-1.453.872 0 1.454.582 1.454 1.454 0 .871-.582 1.453-1.454 1.453Zm13.078 2.906h-8.72v-4.36h8.72v4.36Z",
- fill: "currentColor"
- })));
- };
- /* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (SvgCollection);
- /***/ }),
- /***/ 38520:
- /***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
- "use strict";
- /* harmony export */ __webpack_require__.d(__webpack_exports__, {
- /* harmony export */ "Z": () => (__WEBPACK_DEFAULT_EXPORT__)
- /* harmony export */ });
- /* harmony import */ var react__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(16689);
- /* harmony import */ var react__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_0__);
- var _g, _defs;
- function _extends() { return _extends = Object.assign ? Object.assign.bind() : function (n) { for (var e = 1; e < arguments.length; e++) { var t = arguments[e]; for (var r in t) ({}).hasOwnProperty.call(t, r) && (n[r] = t[r]); } return n; }, _extends.apply(null, arguments); }
- var SvgDevelopers = function SvgDevelopers(props) {
- return /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0__.createElement("svg", _extends({
- width: 24,
- height: 24,
- viewBox: "0 0 24 24",
- fill: "none",
- xmlns: "http://www.w3.org/2000/svg"
- }, props), _g || (_g = /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0__.createElement("g", {
- clipPath: "url(#a)",
- fill: "currentColor"
- }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0__.createElement("path", {
- d: "M4.844 1H.969A.97.97 0 0 0 0 1.969v19.375a.97.97 0 0 0 .969.968h3.875V1ZM6.781 1v21.313h15.5a.97.97 0 0 0 .969-.97V1.97A.97.97 0 0 0 22.281 1h-15.5Zm3.875 3.875h2.906v1.938h-2.906V4.875Zm2.906 13.563h-2.906V16.5h2.906v1.938Zm2.907-3.875h-3.875v-1.938h3.875v1.938Zm2.906-3.876h-5.813V8.75h5.813v1.938Z"
- }))), _defs || (_defs = /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0__.createElement("defs", null, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0__.createElement("clipPath", {
- id: "a"
- }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0__.createElement("path", {
- fill: "currentColor",
- d: "M0 0h23.25v23.25H0z"
- })))));
- };
- /* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (SvgDevelopers);
- /***/ }),
- /***/ 52893:
- /***/ ((module) => {
- // Exports
- module.exports = {
- "backText": "CourseDetails_backText__8Hu7e",
- "headerContainer": "CourseDetails_headerContainer__0KFWS",
- "title": "CourseDetails_title__WmnyB",
- "author": "CourseDetails_author__C0c06",
- "imgContainer": "CourseDetails_imgContainer__iJ_rf",
- "startLearningButton": "CourseDetails_startLearningButton__vdo76"
- };
- /***/ }),
- /***/ 19914:
- /***/ ((module) => {
- // Exports
- module.exports = {
- "completedContainer": "StatusHeader_completedContainer__DjKg6"
- };
- /***/ }),
- /***/ 261:
- /***/ ((module) => {
- // Exports
- module.exports = {
- "container": "TabSwitcherItem_container__l0AFM",
- "value": "TabSwitcherItem_value__9Zast"
- };
- /***/ }),
- /***/ 45699:
- /***/ ((module) => {
- // Exports
- module.exports = {
- "author": "AuthorDetail_author__QNqjO"
- };
- /***/ }),
- /***/ 2338:
- /***/ ((module) => {
- // Exports
- module.exports = {
- "title": "DetailSection_title__4mbZq",
- "container": "DetailSection_container__CnjV5"
- };
- /***/ }),
- /***/ 63955:
- /***/ ((module) => {
- // Exports
- module.exports = {
- "syllabusContainer": "Syllabus_syllabusContainer__3hJSK",
- "container": "Syllabus_container__vPuDB",
- "day": "Syllabus_day__jG8s6"
- };
- /***/ }),
- /***/ 47989:
- /***/ ((module) => {
- // Exports
- module.exports = {
- "container": "Pill_container__FoIEg",
- "small": "Pill_small__zCILo"
- };
- /***/ }),
- /***/ 24001:
- /***/ ((module) => {
- // Exports
- module.exports = {
- "container": "Switch_container__sYEUd",
- "xSmallContainer": "Switch_xSmallContainer__CtQzD",
- "item": "Switch_item__ePHkS",
- "separatorLine": "Switch_separatorLine__Jj73_",
- "separatorLineVisible": "Switch_separatorLineVisible__RnZCc",
- "selectedItemBackgroundContainer": "Switch_selectedItemBackgroundContainer__7F_kF",
- "selectedItemBackground": "Switch_selectedItemBackground__VMOBG",
- "itemNormal": "Switch_itemNormal__pDPXy",
- "itemLarge": "Switch_itemLarge__SCzg2",
- "itemSmall": "Switch_itemSmall__gKpF9",
- "itemXSmall": "Switch_itemXSmall__GcCpL"
- };
- /***/ }),
- /***/ 97523:
- /***/ ((module) => {
- // Exports
- module.exports = {
- "container": "courses_container__h1_I3"
- };
- /***/ }),
- /***/ 41614:
- /***/ ((module, __webpack_exports__, __webpack_require__) => {
- "use strict";
- __webpack_require__.a(module, async (__webpack_handle_async_dependencies__, __webpack_async_result__) => { try {
- /* harmony export */ __webpack_require__.d(__webpack_exports__, {
- /* harmony export */ "Z": () => (__WEBPACK_DEFAULT_EXPORT__)
- /* harmony export */ });
- /* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(20997);
- /* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__);
- /* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(16689);
- /* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__);
- /* harmony import */ var next_router__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(71853);
- /* harmony import */ var next_router__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(next_router__WEBPACK_IMPORTED_MODULE_2__);
- /* harmony import */ var next_translate_useTranslation__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(60866);
- /* harmony import */ var next_translate_useTranslation__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(next_translate_useTranslation__WEBPACK_IMPORTED_MODULE_3__);
- /* harmony import */ var _dls_Button_Button__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(50497);
- /* harmony import */ var _utils_eventLogger__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(55943);
- /* harmony import */ var _utils_navigation__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(57933);
- var __webpack_async_dependencies__ = __webpack_handle_async_dependencies__([_dls_Button_Button__WEBPACK_IMPORTED_MODULE_4__, _utils_eventLogger__WEBPACK_IMPORTED_MODULE_5__, _utils_navigation__WEBPACK_IMPORTED_MODULE_6__]);
- ([_dls_Button_Button__WEBPACK_IMPORTED_MODULE_4__, _utils_eventLogger__WEBPACK_IMPORTED_MODULE_5__, _utils_navigation__WEBPACK_IMPORTED_MODULE_6__] = __webpack_async_dependencies__.then ? (await __webpack_async_dependencies__)() : __webpack_async_dependencies__);
- const StartOrContinueLearning = ({ course , isHeaderButton =true })=>{
- const { t } = next_translate_useTranslation__WEBPACK_IMPORTED_MODULE_3___default()("learn");
- const { lessons , continueFromLesson , id , slug } = course;
- /**
- * there is a corner case when the user enrolls,
- * goes back to main page then clicks start learning again,
- * continueFromLesson is undefined since it has been cached from
- * before the user enrolled.
- */ const redirectToLessonSlug = continueFromLesson || lessons?.[0]?.slug;
- const router = (0,next_router__WEBPACK_IMPORTED_MODULE_2__.useRouter)();
- const userCompletedAnyLesson = lessons.some((lesson)=>lesson.isCompleted === true);
- const onContinueLearningClicked = ()=>{
- (0,_utils_eventLogger__WEBPACK_IMPORTED_MODULE_5__/* .logButtonClick */ .MY)("continue_learning", {
- courseId: id,
- isHeaderButton
- });
- router.push((0,_utils_navigation__WEBPACK_IMPORTED_MODULE_6__/* .getLessonNavigationUrl */ .dC)(slug, redirectToLessonSlug));
- };
- const onStartLearningClicked = ()=>{
- (0,_utils_eventLogger__WEBPACK_IMPORTED_MODULE_5__/* .logButtonClick */ .MY)("start_learning", {
- courseId: id,
- isHeaderButton
- });
- router.push((0,_utils_navigation__WEBPACK_IMPORTED_MODULE_6__/* .getLessonNavigationUrl */ .dC)(slug, redirectToLessonSlug));
- };
- if (userCompletedAnyLesson) {
- return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_dls_Button_Button__WEBPACK_IMPORTED_MODULE_4__/* ["default"] */ .ZP, {
- onClick: onContinueLearningClicked,
- children: t("continue-learning")
- });
- }
- return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_dls_Button_Button__WEBPACK_IMPORTED_MODULE_4__/* ["default"] */ .ZP, {
- onClick: onStartLearningClicked,
- children: t("start-learning")
- });
- };
- /* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (StartOrContinueLearning);
- __webpack_async_result__();
- } catch(e) { __webpack_async_result__(e); } });
- /***/ }),
- /***/ 61284:
- /***/ ((module, __webpack_exports__, __webpack_require__) => {
- "use strict";
- __webpack_require__.a(module, async (__webpack_handle_async_dependencies__, __webpack_async_result__) => { try {
- /* harmony export */ __webpack_require__.d(__webpack_exports__, {
- /* harmony export */ "Z": () => (__WEBPACK_DEFAULT_EXPORT__)
- /* harmony export */ });
- /* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(20997);
- /* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__);
- /* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(16689);
- /* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__);
- /* harmony import */ var next_router__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(71853);
- /* harmony import */ var next_router__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(next_router__WEBPACK_IMPORTED_MODULE_2__);
- /* harmony import */ var next_translate_useTranslation__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(60866);
- /* harmony import */ var next_translate_useTranslation__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(next_translate_useTranslation__WEBPACK_IMPORTED_MODULE_3__);
- /* harmony import */ var _StatusHeader_module_scss__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(19914);
- /* harmony import */ var _StatusHeader_module_scss__WEBPACK_IMPORTED_MODULE_15___default = /*#__PURE__*/__webpack_require__.n(_StatusHeader_module_scss__WEBPACK_IMPORTED_MODULE_15__);
- /* harmony import */ var _components_Course_Buttons_StartOrContinueLearning__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(41614);
- /* harmony import */ var _components_Course_CourseFeedback__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(18370);
- /* harmony import */ var _dls_Button_Button__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(50497);
- /* harmony import */ var _dls_Pill__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(78945);
- /* harmony import */ var _dls_Toast_Toast__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(79717);
- /* harmony import */ var _hooks_useMutateWithoutRevalidation__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(61368);
- /* harmony import */ var _utils_auth_api__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(37883);
- /* harmony import */ var _utils_auth_apiPaths__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(13830);
- /* harmony import */ var _utils_auth_login__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(22197);
- /* harmony import */ var _utils_eventLogger__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(55943);
- /* harmony import */ var _utils_navigation__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(57933);
- var __webpack_async_dependencies__ = __webpack_handle_async_dependencies__([_components_Course_Buttons_StartOrContinueLearning__WEBPACK_IMPORTED_MODULE_4__, _components_Course_CourseFeedback__WEBPACK_IMPORTED_MODULE_5__, _dls_Button_Button__WEBPACK_IMPORTED_MODULE_6__, _dls_Toast_Toast__WEBPACK_IMPORTED_MODULE_8__, _hooks_useMutateWithoutRevalidation__WEBPACK_IMPORTED_MODULE_9__, _utils_auth_login__WEBPACK_IMPORTED_MODULE_12__, _utils_eventLogger__WEBPACK_IMPORTED_MODULE_13__, _utils_navigation__WEBPACK_IMPORTED_MODULE_14__]);
- ([_components_Course_Buttons_StartOrContinueLearning__WEBPACK_IMPORTED_MODULE_4__, _components_Course_CourseFeedback__WEBPACK_IMPORTED_MODULE_5__, _dls_Button_Button__WEBPACK_IMPORTED_MODULE_6__, _dls_Toast_Toast__WEBPACK_IMPORTED_MODULE_8__, _hooks_useMutateWithoutRevalidation__WEBPACK_IMPORTED_MODULE_9__, _utils_auth_login__WEBPACK_IMPORTED_MODULE_12__, _utils_eventLogger__WEBPACK_IMPORTED_MODULE_13__, _utils_navigation__WEBPACK_IMPORTED_MODULE_14__] = __webpack_async_dependencies__.then ? (await __webpack_async_dependencies__)() : __webpack_async_dependencies__);
- /* eslint-disable react-func/max-lines-per-function */
- const StatusHeader = ({ course , isCTA =false })=>{
- const { title , id , isUserEnrolled , slug , isCompleted , lessons } = course;
- const { 0: isLoading , 1: setIsLoading } = (0,react__WEBPACK_IMPORTED_MODULE_1__.useState)(false);
- const toast = (0,_dls_Toast_Toast__WEBPACK_IMPORTED_MODULE_8__/* .useToast */ .pm)();
- const router = (0,next_router__WEBPACK_IMPORTED_MODULE_2__.useRouter)();
- const { t } = next_translate_useTranslation__WEBPACK_IMPORTED_MODULE_3___default()("learn");
- const mutate = (0,_hooks_useMutateWithoutRevalidation__WEBPACK_IMPORTED_MODULE_9__/* ["default"] */ .Z)();
- const onEnrollClicked = ()=>{
- if ((0,_utils_auth_login__WEBPACK_IMPORTED_MODULE_12__/* .isLoggedIn */ .jl)()) {
- (0,_utils_eventLogger__WEBPACK_IMPORTED_MODULE_13__/* .logButtonClick */ .MY)("user_enroll_course", {
- courseId: id,
- isCTA
- });
- setIsLoading(true);
- (0,_utils_auth_api__WEBPACK_IMPORTED_MODULE_10__/* .enrollUser */ .xh)(course.id).then(()=>{
- toast(t("enroll-success", {
- title
- }), {
- status: _dls_Toast_Toast__WEBPACK_IMPORTED_MODULE_8__/* .ToastStatus.Success */ .YZ.Success
- });
- mutate((0,_utils_auth_apiPaths__WEBPACK_IMPORTED_MODULE_11__/* .makeGetCourseUrl */ .vp)(slug), (currentCourse)=>{
- return {
- ...currentCourse,
- isUserEnrolled: true
- };
- });
- // if the course has lessons, redirect to the first lesson
- if (lessons?.length > 0) {
- router.replace((0,_utils_navigation__WEBPACK_IMPORTED_MODULE_14__/* .getLessonNavigationUrl */ .dC)(slug, lessons[0].slug));
- }
- }).catch(()=>{
- toast(t("common:error.general"), {
- status: _dls_Toast_Toast__WEBPACK_IMPORTED_MODULE_8__/* .ToastStatus.Error */ .YZ.Error
- });
- }).finally(()=>{
- setIsLoading(false);
- });
- } else {
- (0,_utils_eventLogger__WEBPACK_IMPORTED_MODULE_13__/* .logButtonClick */ .MY)("guest_enroll_course", {
- courseId: id,
- isCTA
- });
- router.replace((0,_utils_navigation__WEBPACK_IMPORTED_MODULE_14__/* .getLoginNavigationUrl */ .gk)((0,_utils_navigation__WEBPACK_IMPORTED_MODULE_14__/* .getCourseNavigationUrl */ .ES)(slug)));
- }
- };
- if (isCTA) {
- if (isUserEnrolled === true) {
- return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.Fragment, {});
- }
- return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_dls_Button_Button__WEBPACK_IMPORTED_MODULE_6__/* ["default"] */ .ZP, {
- isDisabled: isLoading,
- isLoading: isLoading,
- onClick: onEnrollClicked,
- children: t("enroll")
- });
- }
- if (isCompleted) {
- return /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", {
- className: (_StatusHeader_module_scss__WEBPACK_IMPORTED_MODULE_15___default().completedContainer),
- children: [
- /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_dls_Pill__WEBPACK_IMPORTED_MODULE_7__/* ["default"] */ .Z, {
- children: t("completed")
- }),
- course?.userHasFeedback === false && /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_components_Course_CourseFeedback__WEBPACK_IMPORTED_MODULE_5__/* ["default"] */ .Z, {
- course: course,
- source: _components_Course_CourseFeedback__WEBPACK_IMPORTED_MODULE_5__/* .FeedbackSource.CoursePage */ .E.CoursePage
- })
- ]
- });
- }
- if (isUserEnrolled === true) {
- return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_components_Course_Buttons_StartOrContinueLearning__WEBPACK_IMPORTED_MODULE_4__/* ["default"] */ .Z, {
- course: course
- });
- }
- return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_dls_Button_Button__WEBPACK_IMPORTED_MODULE_6__/* ["default"] */ .ZP, {
- isDisabled: isLoading,
- isLoading: isLoading,
- onClick: onEnrollClicked,
- children: t("enroll")
- });
- };
- /* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (StatusHeader);
- __webpack_async_result__();
- } catch(e) { __webpack_async_result__(e); } });
- /***/ }),
- /***/ 49402:
- /***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
- "use strict";
- /* harmony export */ __webpack_require__.d(__webpack_exports__, {
- /* harmony export */ "Z": () => (__WEBPACK_DEFAULT_EXPORT__)
- /* harmony export */ });
- /* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(20997);
- /* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__);
- /* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(16689);
- /* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__);
- /* harmony import */ var _TabSwitcherItem_module_scss__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(261);
- /* harmony import */ var _TabSwitcherItem_module_scss__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_TabSwitcherItem_module_scss__WEBPACK_IMPORTED_MODULE_2__);
- const TabSwitcherItem = ({ icon , value })=>{
- return /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", {
- className: (_TabSwitcherItem_module_scss__WEBPACK_IMPORTED_MODULE_2___default().container),
- children: [
- icon,
- " ",
- /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("p", {
- className: (_TabSwitcherItem_module_scss__WEBPACK_IMPORTED_MODULE_2___default().value),
- children: value
- })
- ]
- });
- };
- /* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (TabSwitcherItem);
- /***/ }),
- /***/ 81454:
- /***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
- "use strict";
- /* harmony export */ __webpack_require__.d(__webpack_exports__, {
- /* harmony export */ "Z": () => (__WEBPACK_DEFAULT_EXPORT__)
- /* harmony export */ });
- /* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(20997);
- /* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__);
- /* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(16689);
- /* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__);
- /* harmony import */ var _AuthorDetail_module_scss__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(45699);
- /* harmony import */ var _AuthorDetail_module_scss__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_AuthorDetail_module_scss__WEBPACK_IMPORTED_MODULE_2__);
- const AuthorDetail = ({ author })=>{
- return /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.Fragment, {
- children: [
- /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", {
- className: (_AuthorDetail_module_scss__WEBPACK_IMPORTED_MODULE_2___default().author),
- children: author.name
- }),
- " ",
- /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", {
- children: author.biography
- })
- ]
- });
- };
- /* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (AuthorDetail);
- /***/ }),
- /***/ 63580:
- /***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
- "use strict";
- /* harmony export */ __webpack_require__.d(__webpack_exports__, {
- /* harmony export */ "Z": () => (__WEBPACK_DEFAULT_EXPORT__)
- /* harmony export */ });
- /* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(20997);
- /* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__);
- /* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(16689);
- /* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__);
- /* harmony import */ var _DetailSection_module_scss__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(2338);
- /* harmony import */ var _DetailSection_module_scss__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_DetailSection_module_scss__WEBPACK_IMPORTED_MODULE_2__);
- const DetailSection = ({ title , description })=>{
- return /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", {
- className: (_DetailSection_module_scss__WEBPACK_IMPORTED_MODULE_2___default().container),
- children: [
- /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", {
- className: (_DetailSection_module_scss__WEBPACK_IMPORTED_MODULE_2___default().title),
- children: [
- `${title}: `,
- " "
- ]
- }),
- /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", {
- className: (_DetailSection_module_scss__WEBPACK_IMPORTED_MODULE_2___default().description),
- children: description
- })
- ]
- });
- };
- /* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (DetailSection);
- /***/ }),
- /***/ 53227:
- /***/ ((module, __webpack_exports__, __webpack_require__) => {
- "use strict";
- __webpack_require__.a(module, async (__webpack_handle_async_dependencies__, __webpack_async_result__) => { try {
- /* harmony export */ __webpack_require__.d(__webpack_exports__, {
- /* harmony export */ "Z": () => (__WEBPACK_DEFAULT_EXPORT__)
- /* harmony export */ });
- /* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(20997);
- /* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__);
- /* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(16689);
- /* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__);
- /* harmony import */ var _milkdown_react__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(76915);
- /* harmony import */ var next_translate_useTranslation__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(60866);
- /* harmony import */ var next_translate_useTranslation__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(next_translate_useTranslation__WEBPACK_IMPORTED_MODULE_3__);
- /* harmony import */ var _DetailSection__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(63580);
- /* harmony import */ var _components_MarkdownEditor__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(3177);
- var __webpack_async_dependencies__ = __webpack_handle_async_dependencies__([_milkdown_react__WEBPACK_IMPORTED_MODULE_2__, _components_MarkdownEditor__WEBPACK_IMPORTED_MODULE_5__]);
- ([_milkdown_react__WEBPACK_IMPORTED_MODULE_2__, _components_MarkdownEditor__WEBPACK_IMPORTED_MODULE_5__] = __webpack_async_dependencies__.then ? (await __webpack_async_dependencies__)() : __webpack_async_dependencies__);
- /* eslint-disable unicorn/no-array-reduce */
- const MainDetails = ({ course })=>{
- const { t } = next_translate_useTranslation__WEBPACK_IMPORTED_MODULE_3___default()("learn");
- const { description , dailyMinutes , lessons =[] } = course;
- // const tagsString = tags?.reduce((acc, currentValue) => {
- // if (!acc) return currentValue;
- // return `${acc}, ${currentValue}`;
- // }, '');
- return /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.Fragment, {
- children: [
- /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_DetailSection__WEBPACK_IMPORTED_MODULE_4__/* ["default"] */ .Z, {
- title: t("learn-duration"),
- description: t("duration-daily", {
- dailyMins: dailyMinutes,
- days: lessons.length
- })
- }),
- /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_milkdown_react__WEBPACK_IMPORTED_MODULE_2__.MilkdownProvider, {
- children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_DetailSection__WEBPACK_IMPORTED_MODULE_4__/* ["default"] */ .Z, {
- title: t("description"),
- description: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_components_MarkdownEditor__WEBPACK_IMPORTED_MODULE_5__/* ["default"] */ .Z, {
- isEditable: false,
- defaultValue: description
- })
- })
- })
- ]
- });
- };
- /* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (MainDetails);
- __webpack_async_result__();
- } catch(e) { __webpack_async_result__(e); } });
- /***/ }),
- /***/ 65856:
- /***/ ((module, __webpack_exports__, __webpack_require__) => {
- "use strict";
- __webpack_require__.a(module, async (__webpack_handle_async_dependencies__, __webpack_async_result__) => { try {
- /* harmony export */ __webpack_require__.d(__webpack_exports__, {
- /* harmony export */ "Z": () => (__WEBPACK_DEFAULT_EXPORT__)
- /* harmony export */ });
- /* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(20997);
- /* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__);
- /* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(16689);
- /* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__);
- /* harmony import */ var next_translate_useTranslation__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(60866);
- /* harmony import */ var next_translate_useTranslation__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(next_translate_useTranslation__WEBPACK_IMPORTED_MODULE_2__);
- /* harmony import */ var _Syllabus_module_scss__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(63955);
- /* harmony import */ var _Syllabus_module_scss__WEBPACK_IMPORTED_MODULE_9___default = /*#__PURE__*/__webpack_require__.n(_Syllabus_module_scss__WEBPACK_IMPORTED_MODULE_9__);
- /* harmony import */ var _components_Course_CompletedTick__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(86120);
- /* harmony import */ var _dls_Link_Link__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(61239);
- /* harmony import */ var _utils_auth_login__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(22197);
- /* harmony import */ var _utils_eventLogger__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(55943);
- /* harmony import */ var _utils_locale__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(24709);
- /* harmony import */ var _utils_navigation__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(57933);
- var __webpack_async_dependencies__ = __webpack_handle_async_dependencies__([_utils_auth_login__WEBPACK_IMPORTED_MODULE_5__, _utils_eventLogger__WEBPACK_IMPORTED_MODULE_6__, _utils_navigation__WEBPACK_IMPORTED_MODULE_8__]);
- ([_utils_auth_login__WEBPACK_IMPORTED_MODULE_5__, _utils_eventLogger__WEBPACK_IMPORTED_MODULE_6__, _utils_navigation__WEBPACK_IMPORTED_MODULE_8__] = __webpack_async_dependencies__.then ? (await __webpack_async_dependencies__)() : __webpack_async_dependencies__);
- /* eslint-disable react/no-array-index-key */
- const Syllabus = ({ course })=>{
- const { lessons =[] , slug: courseSlug } = course;
- const { t , lang } = next_translate_useTranslation__WEBPACK_IMPORTED_MODULE_2___default()("learn");
- const isUserLoggedIn = (0,_utils_auth_login__WEBPACK_IMPORTED_MODULE_5__/* .isLoggedIn */ .jl)();
- const onDayClick = (dayNumber, lessonId)=>{
- (0,_utils_eventLogger__WEBPACK_IMPORTED_MODULE_6__/* .logButtonClick */ .MY)(isUserLoggedIn ? "course_syllabus_day" : "guest_course_syllabus_day", {
- courseId: course.id,
- dayNumber,
- lessonId
- });
- };
- return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", {
- className: (_Syllabus_module_scss__WEBPACK_IMPORTED_MODULE_9___default().syllabusContainer),
- children: lessons.map((lesson, index)=>{
- const dayNumber = index + 1;
- const { title , isCompleted , id , slug } = lesson;
- const url = (0,_utils_navigation__WEBPACK_IMPORTED_MODULE_8__/* .getLessonNavigationUrl */ .dC)(courseSlug, slug);
- return /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("p", {
- className: (_Syllabus_module_scss__WEBPACK_IMPORTED_MODULE_9___default().container),
- children: [
- /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", {
- className: (_Syllabus_module_scss__WEBPACK_IMPORTED_MODULE_9___default().day),
- children: `${t("day")} ${(0,_utils_locale__WEBPACK_IMPORTED_MODULE_7__/* .toLocalizedNumber */ .rQ)(dayNumber, lang)}`
- }),
- /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("span", {
- children: [
- `: `,
- /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_dls_Link_Link__WEBPACK_IMPORTED_MODULE_4__/* ["default"] */ .Z, {
- onClick: ()=>onDayClick(dayNumber, id),
- href: isUserLoggedIn ? url : (0,_utils_navigation__WEBPACK_IMPORTED_MODULE_8__/* .getLoginNavigationUrl */ .gk)(url),
- variant: _dls_Link_Link__WEBPACK_IMPORTED_MODULE_4__/* .LinkVariant.Highlight */ .r.Highlight,
- children: title
- }),
- isCompleted ? /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_components_Course_CompletedTick__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .Z, {}) : ""
- ]
- })
- ]
- }, index);
- })
- });
- };
- /* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (Syllabus);
- __webpack_async_result__();
- } catch(e) { __webpack_async_result__(e); } });
- /***/ }),
- /***/ 84346:
- /***/ ((module, __webpack_exports__, __webpack_require__) => {
- "use strict";
- __webpack_require__.a(module, async (__webpack_handle_async_dependencies__, __webpack_async_result__) => { try {
- /* harmony export */ __webpack_require__.d(__webpack_exports__, {
- /* harmony export */ "Z": () => (__WEBPACK_DEFAULT_EXPORT__)
- /* harmony export */ });
- /* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(20997);
- /* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__);
- /* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(16689);
- /* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__);
- /* harmony import */ var next_image__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(7477);
- /* harmony import */ var next_image__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(next_image__WEBPACK_IMPORTED_MODULE_2__);
- /* harmony import */ var next_translate_useTranslation__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(60866);
- /* harmony import */ var next_translate_useTranslation__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(next_translate_useTranslation__WEBPACK_IMPORTED_MODULE_3__);
- /* harmony import */ var _CourseDetails_module_scss__WEBPACK_IMPORTED_MODULE_19__ = __webpack_require__(52893);
- /* harmony import */ var _CourseDetails_module_scss__WEBPACK_IMPORTED_MODULE_19___default = /*#__PURE__*/__webpack_require__.n(_CourseDetails_module_scss__WEBPACK_IMPORTED_MODULE_19__);
- /* harmony import */ var _components_Course_Buttons_StartOrContinueLearning__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(41614);
- /* harmony import */ var _components_Course_ContentContainer__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(79215);
- /* harmony import */ var _components_Course_CourseDetails_StatusHeader__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(61284);
- /* harmony import */ var _components_Course_CourseDetails_Tabs_MainDetails__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(53227);
- /* harmony import */ var _components_Course_CourseDetails_Tabs_MainDetails_DetailSection__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(63580);
- /* harmony import */ var _components_Course_CourseDetails_Tabs_MainDetails_DetailSection_AuthorDetail__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(81454);
- /* harmony import */ var _components_Course_CourseDetails_Tabs_Syllabus__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(65856);
- /* harmony import */ var _components_Course_CourseDetails_TabSwitcherItem__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(49402);
- /* harmony import */ var _dls_Button_Button__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(50497);
- /* harmony import */ var _dls_Switch_Switch__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(66025);
- /* harmony import */ var _icons_collection_svg__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(38264);
- /* harmony import */ var _icons_developers_svg__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(38520);
- /* harmony import */ var _icons_west_svg__WEBPACK_IMPORTED_MODULE_16__ = __webpack_require__(58421);
- /* harmony import */ var _utils_eventLogger__WEBPACK_IMPORTED_MODULE_17__ = __webpack_require__(55943);
- /* harmony import */ var _utils_navigation__WEBPACK_IMPORTED_MODULE_18__ = __webpack_require__(57933);
- var __webpack_async_dependencies__ = __webpack_handle_async_dependencies__([_components_Course_Buttons_StartOrContinueLearning__WEBPACK_IMPORTED_MODULE_4__, _components_Course_CourseDetails_StatusHeader__WEBPACK_IMPORTED_MODULE_6__, _components_Course_CourseDetails_Tabs_MainDetails__WEBPACK_IMPORTED_MODULE_7__, _components_Course_CourseDetails_Tabs_Syllabus__WEBPACK_IMPORTED_MODULE_10__, _dls_Button_Button__WEBPACK_IMPORTED_MODULE_12__, _utils_eventLogger__WEBPACK_IMPORTED_MODULE_17__, _utils_navigation__WEBPACK_IMPORTED_MODULE_18__]);
- ([_components_Course_Buttons_StartOrContinueLearning__WEBPACK_IMPORTED_MODULE_4__, _components_Course_CourseDetails_StatusHeader__WEBPACK_IMPORTED_MODULE_6__, _components_Course_CourseDetails_Tabs_MainDetails__WEBPACK_IMPORTED_MODULE_7__, _components_Course_CourseDetails_Tabs_Syllabus__WEBPACK_IMPORTED_MODULE_10__, _dls_Button_Button__WEBPACK_IMPORTED_MODULE_12__, _utils_eventLogger__WEBPACK_IMPORTED_MODULE_17__, _utils_navigation__WEBPACK_IMPORTED_MODULE_18__] = __webpack_async_dependencies__.then ? (await __webpack_async_dependencies__)() : __webpack_async_dependencies__);
- var Tab;
- (function(Tab) {
- Tab["MAIN"] = "main";
- Tab["SYLLABUS"] = "syllabus";
- })(Tab || (Tab = {}));
- const CourseDetails = ({ course })=>{
- const { title , image , id } = course;
- const { t } = next_translate_useTranslation__WEBPACK_IMPORTED_MODULE_3___default()("learn");
- const { 0: selectedTab , 1: setSelectedTab } = (0,react__WEBPACK_IMPORTED_MODULE_1__.useState)(Tab.MAIN);
- const onTabChange = (value)=>{
- (0,_utils_eventLogger__WEBPACK_IMPORTED_MODULE_17__/* .logEvent */ .Kz)("course_details_tab_change", {
- courseId: id,
- tab: value
- });
- setSelectedTab(value);
- };
- const onBackButtonClicked = ()=>{
- (0,_utils_eventLogger__WEBPACK_IMPORTED_MODULE_17__/* .logButtonClick */ .MY)("back_to_courses_course_details", {
- courseId: id
- });
- };
- const tabs = (0,react__WEBPACK_IMPORTED_MODULE_1__.useMemo)(()=>[
- {
- name: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_components_Course_CourseDetails_TabSwitcherItem__WEBPACK_IMPORTED_MODULE_11__/* ["default"] */ .Z, {
- icon: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_icons_collection_svg__WEBPACK_IMPORTED_MODULE_14__/* ["default"] */ .Z, {}),
- value: t("tabs.main")
- }),
- value: Tab.MAIN
- },
- {
- name: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_components_Course_CourseDetails_TabSwitcherItem__WEBPACK_IMPORTED_MODULE_11__/* ["default"] */ .Z, {
- icon: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_icons_developers_svg__WEBPACK_IMPORTED_MODULE_15__/* ["default"] */ .Z, {}),
- value: t("tabs.syllabus")
- }),
- value: Tab.SYLLABUS
- },
- ], [
- t
- ]);
- const tabComponents = (0,react__WEBPACK_IMPORTED_MODULE_1__.useMemo)(()=>({
- [Tab.MAIN]: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_components_Course_CourseDetails_Tabs_MainDetails__WEBPACK_IMPORTED_MODULE_7__/* ["default"] */ .Z, {
- course: course
- }),
- [Tab.SYLLABUS]: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_components_Course_CourseDetails_Tabs_Syllabus__WEBPACK_IMPORTED_MODULE_10__/* ["default"] */ .Z, {
- course: course
- })
- }), [
- course
- ]);
- return /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)(_components_Course_ContentContainer__WEBPACK_IMPORTED_MODULE_5__/* ["default"] */ .Z, {
- children: [
- /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)(_dls_Button_Button__WEBPACK_IMPORTED_MODULE_12__/* ["default"] */ .ZP, {
- onClick: onBackButtonClicked,
- href: (0,_utils_navigation__WEBPACK_IMPORTED_MODULE_18__/* .getCoursesNavigationUrl */ .ty)(),
- variant: _dls_Button_Button__WEBPACK_IMPORTED_MODULE_12__/* .ButtonVariant.Ghost */ .Wu.Ghost,
- children: [
- /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_icons_west_svg__WEBPACK_IMPORTED_MODULE_16__/* ["default"] */ .Z, {}),
- /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("p", {
- className: (_CourseDetails_module_scss__WEBPACK_IMPORTED_MODULE_19___default().backText),
- children: t("back-to-learning-plans")
- })
- ]
- }),
- /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", {
- className: (_CourseDetails_module_scss__WEBPACK_IMPORTED_MODULE_19___default().headerContainer),
- children: [
- /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", {
- children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("p", {
- className: (_CourseDetails_module_scss__WEBPACK_IMPORTED_MODULE_19___default().title),
- children: title
- })
- }),
- /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_components_Course_CourseDetails_StatusHeader__WEBPACK_IMPORTED_MODULE_6__/* ["default"] */ .Z, {
- course: course
- })
- ]
- }),
- /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", {
- className: (_CourseDetails_module_scss__WEBPACK_IMPORTED_MODULE_19___default().imgContainer),
- children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx((next_image__WEBPACK_IMPORTED_MODULE_2___default()), {
- alt: title,
- src: image,
- layout: "fill"
- })
- }),
- /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_dls_Switch_Switch__WEBPACK_IMPORTED_MODULE_13__/* ["default"] */ .Z, {
- selected: selectedTab,
- items: tabs,
- onSelect: onTabChange
- }),
- tabComponents[selectedTab],
- selectedTab === Tab.MAIN && /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.Fragment, {
- children: [
- !course.isUserEnrolled && /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.Fragment, {
- children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_components_Course_CourseDetails_StatusHeader__WEBPACK_IMPORTED_MODULE_6__/* ["default"] */ .Z, {
- course: course,
- isCTA: true
- })
- }),
- /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_components_Course_CourseDetails_Tabs_MainDetails_DetailSection__WEBPACK_IMPORTED_MODULE_8__/* ["default"] */ .Z, {
- title: t("about-author"),
- description: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_components_Course_CourseDetails_Tabs_MainDetails_DetailSection_AuthorDetail__WEBPACK_IMPORTED_MODULE_9__/* ["default"] */ .Z, {
- author: course.author
- })
- }),
- course.isUserEnrolled && /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", {
- className: (_CourseDetails_module_scss__WEBPACK_IMPORTED_MODULE_19___default().startLearningButton),
- children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_components_Course_Buttons_StartOrContinueLearning__WEBPACK_IMPORTED_MODULE_4__/* ["default"] */ .Z, {
- course: course,
- isHeaderButton: false
- })
- })
- ]
- })
- ]
- });
- };
- /* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (CourseDetails);
- __webpack_async_result__();
- } catch(e) { __webpack_async_result__(e); } });
- /***/ }),
- /***/ 78945:
- /***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
- "use strict";
- /* harmony export */ __webpack_require__.d(__webpack_exports__, {
- /* harmony export */ "Z": () => (__WEBPACK_DEFAULT_EXPORT__),
- /* harmony export */ "n": () => (/* binding */ PillSize)
- /* harmony export */ });
- /* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(20997);
- /* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__);
- /* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(16689);
- /* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__);
- /* harmony import */ var classnames__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(59003);
- /* harmony import */ var classnames__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(classnames__WEBPACK_IMPORTED_MODULE_2__);
- /* harmony import */ var _Pill_module_scss__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(47989);
- /* harmony import */ var _Pill_module_scss__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_Pill_module_scss__WEBPACK_IMPORTED_MODULE_3__);
- var PillSize;
- (function(PillSize) {
- PillSize["SMALL"] = "small";
- PillSize["MEDIUM"] = "medium";
- })(PillSize || (PillSize = {}));
- const Pill = ({ children , size =PillSize.MEDIUM })=>{
- return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", {
- className: classnames__WEBPACK_IMPORTED_MODULE_2___default()((_Pill_module_scss__WEBPACK_IMPORTED_MODULE_3___default().container), {
- [(_Pill_module_scss__WEBPACK_IMPORTED_MODULE_3___default().medium)]: size === PillSize.MEDIUM,
- [(_Pill_module_scss__WEBPACK_IMPORTED_MODULE_3___default().small)]: size === PillSize.SMALL
- }),
- children: children
- });
- };
- /* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (Pill);
- /***/ }),
- /***/ 66025:
- /***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
- "use strict";
- /* harmony export */ __webpack_require__.d(__webpack_exports__, {
- /* harmony export */ "E": () => (/* binding */ SwitchSize),
- /* harmony export */ "Z": () => (__WEBPACK_DEFAULT_EXPORT__)
- /* harmony export */ });
- /* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(20997);
- /* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__);
- /* harmony import */ var classnames__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(59003);
- /* harmony import */ var classnames__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(classnames__WEBPACK_IMPORTED_MODULE_1__);
- /* harmony import */ var lodash_range__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(64042);
- /* harmony import */ var lodash_range__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(lodash_range__WEBPACK_IMPORTED_MODULE_2__);
- /* harmony import */ var next_router__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(71853);
- /* harmony import */ var next_router__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(next_router__WEBPACK_IMPORTED_MODULE_3__);
- /* harmony import */ var _Switch_module_scss__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(24001);
- /* harmony import */ var _Switch_module_scss__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(_Switch_module_scss__WEBPACK_IMPORTED_MODULE_5__);
- /* harmony import */ var _utils_locale__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(24709);
- var SwitchSize;
- (function(SwitchSize) {
- SwitchSize["XSmall"] = "xsmall";
- SwitchSize["Small"] = "small";
- SwitchSize["Normal"] = "normal";
- SwitchSize["Large"] = "large";
- })(SwitchSize || (SwitchSize = {}));
- const Switch = ({ items , onSelect , selected , size =SwitchSize.Normal })=>{
- const selectedIndex = items.findIndex((item)=>item.value === selected);
- const { locale } = (0,next_router__WEBPACK_IMPORTED_MODULE_3__.useRouter)();
- return /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", {
- className: classnames__WEBPACK_IMPORTED_MODULE_1___default()((_Switch_module_scss__WEBPACK_IMPORTED_MODULE_5___default().container), {
- [(_Switch_module_scss__WEBPACK_IMPORTED_MODULE_5___default().xSmallContainer)]: size === SwitchSize.XSmall
- }),
- children: [
- items.map((item)=>/*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("button", {
- disabled: item.disabled,
- type: "button",
- className: classnames__WEBPACK_IMPORTED_MODULE_1___default()((_Switch_module_scss__WEBPACK_IMPORTED_MODULE_5___default().item), selected === item.value && (_Switch_module_scss__WEBPACK_IMPORTED_MODULE_5___default().itemSelected), {
- [(_Switch_module_scss__WEBPACK_IMPORTED_MODULE_5___default().itemLarge)]: size === SwitchSize.Large,
- [(_Switch_module_scss__WEBPACK_IMPORTED_MODULE_5___default().itemNormal)]: size === SwitchSize.Normal,
- [(_Switch_module_scss__WEBPACK_IMPORTED_MODULE_5___default().itemSmall)]: size === SwitchSize.Small,
- [(_Switch_module_scss__WEBPACK_IMPORTED_MODULE_5___default().itemXSmall)]: size === SwitchSize.XSmall
- }),
- onClick: ()=>onSelect(item.value),
- children: item.name
- }, item.value)),
- items.length > 2 && lodash_range__WEBPACK_IMPORTED_MODULE_2___default()(1, items.length).map((i)=>{
- return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", {
- className: classnames__WEBPACK_IMPORTED_MODULE_1___default()((_Switch_module_scss__WEBPACK_IMPORTED_MODULE_5___default().separatorLine), {
- [(_Switch_module_scss__WEBPACK_IMPORTED_MODULE_5___default().separatorLineVisible)]: selectedIndex !== i && selectedIndex !== i - 1
- }),
- style: {
- width: `${100 / items.length}%`,
- transform: `translateX(${100 * i}%)`
- }
- }, i);
- }),
- /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", {
- className: (_Switch_module_scss__WEBPACK_IMPORTED_MODULE_5___default().selectedItemBackgroundContainer),
- style: {
- width: `${1 / items.length * 100}%`,
- transform: `translateX(${(0,_utils_locale__WEBPACK_IMPORTED_MODULE_4__/* .isRTLLocale */ .iS)(locale) ? "-" : ""}${selectedIndex * 100}%)`
- },
- children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", {
- className: (_Switch_module_scss__WEBPACK_IMPORTED_MODULE_5___default().selectedItemBackground)
- })
- })
- ]
- });
- };
- /* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (Switch);
- /***/ }),
- /***/ 45137:
- /***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
- "use strict";
- /* harmony export */ __webpack_require__.d(__webpack_exports__, {
- /* harmony export */ "Dp": () => (/* binding */ ONE_WEEK_REVALIDATION_PERIOD_SECONDS),
- /* harmony export */ "eW": () => (/* binding */ REVALIDATION_PERIOD_ON_ERROR_SECONDS),
- /* harmony export */ "gi": () => (/* binding */ ONE_MONTH_REVALIDATION_PERIOD_SECONDS)
- /* harmony export */ });
- /* unused harmony export ONE_DAY_REVALIDATION_PERIOD_SECONDS */
- const REVALIDATION_PERIOD_ON_ERROR_SECONDS = 604800; // 7 days. TODO: @osama update the naming + value when we revert this back
- const ONE_DAY_REVALIDATION_PERIOD_SECONDS = 86400; // 1 day
- const ONE_WEEK_REVALIDATION_PERIOD_SECONDS = 604800; // 7 days
- const ONE_MONTH_REVALIDATION_PERIOD_SECONDS = 2592000; // 30 days
- /***/ }),
- /***/ 75184:
- /***/ ((module) => {
- "use strict";
- module.exports = require("@reduxjs/toolkit");
- /***/ }),
- /***/ 58097:
- /***/ ((module) => {
- "use strict";
- module.exports = require("@sentry/nextjs");
- /***/ }),
- /***/ 59003:
- /***/ ((module) => {
- "use strict";
- module.exports = require("classnames");
- /***/ }),
- /***/ 59606:
- /***/ ((module) => {
- "use strict";
- module.exports = require("humps");
- /***/ }),
- /***/ 59969:
- /***/ ((module) => {
- "use strict";
- module.exports = require("lodash/capitalize");
- /***/ }),
- /***/ 12372:
- /***/ ((module) => {
- "use strict";
- module.exports = require("lodash/findKey");
- /***/ }),
- /***/ 98492:
- /***/ ((module) => {
- "use strict";
- module.exports = require("lodash/groupBy");
- /***/ }),
- /***/ 35526:
- /***/ ((module) => {
- "use strict";
- module.exports = require("lodash/random");
- /***/ }),
- /***/ 64042:
- /***/ ((module) => {
- "use strict";
- module.exports = require("lodash/range");
- /***/ }),
- /***/ 16641:
- /***/ ((module) => {
- "use strict";
- module.exports = require("next-seo");
- /***/ }),
- /***/ 74137:
- /***/ ((module) => {
- "use strict";
- module.exports = require("next-translate/Trans");
- /***/ }),
- /***/ 60866:
- /***/ ((module) => {
- "use strict";
- module.exports = require("next-translate/useTranslation");
- /***/ }),
- /***/ 3280:
- /***/ ((module) => {
- "use strict";
- module.exports = require("next/dist/shared/lib/app-router-context.js");
- /***/ }),
- /***/ 92796:
- /***/ ((module) => {
- "use strict";
- module.exports = require("next/dist/shared/lib/head-manager-context.js");
- /***/ }),
- /***/ 94957:
- /***/ ((module) => {
- "use strict";
- module.exports = require("next/dist/shared/lib/head.js");
- /***/ }),
- /***/ 3539:
- /***/ ((module) => {
- "use strict";
- module.exports = require("next/dist/shared/lib/i18n/detect-domain-locale.js");
- /***/ }),
- /***/ 34014:
- /***/ ((module) => {
- "use strict";
- module.exports = require("next/dist/shared/lib/i18n/normalize-locale-path.js");
- /***/ }),
- /***/ 50744:
- /***/ ((module) => {
- "use strict";
- module.exports = require("next/dist/shared/lib/image-config-context.js");
- /***/ }),
- /***/ 35843:
- /***/ ((module) => {
- "use strict";
- module.exports = require("next/dist/shared/lib/image-config.js");
- /***/ }),
- /***/ 78524:
- /***/ ((module) => {
- "use strict";
- module.exports = require("next/dist/shared/lib/is-plain-object.js");
- /***/ }),
- /***/ 78020:
- /***/ ((module) => {
- "use strict";
- module.exports = require("next/dist/shared/lib/mitt.js");
- /***/ }),
- /***/ 64406:
- /***/ ((module) => {
- "use strict";
- module.exports = require("next/dist/shared/lib/page-path/denormalize-page-path.js");
- /***/ }),
- /***/ 24964:
- /***/ ((module) => {
- "use strict";
- module.exports = require("next/dist/shared/lib/router-context.js");
- /***/ }),
- /***/ 93431:
- /***/ ((module) => {
- "use strict";
- module.exports = require("next/dist/shared/lib/router/utils/add-locale.js");
- /***/ }),
- /***/ 11751:
- /***/ ((module) => {
- "use strict";
- module.exports = require("next/dist/shared/lib/router/utils/add-path-prefix.js");
- /***/ }),
- /***/ 46220:
- /***/ ((module) => {
- "use strict";
- module.exports = require("next/dist/shared/lib/router/utils/compare-states.js");
- /***/ }),
- /***/ 10299:
- /***/ ((module) => {
- "use strict";
- module.exports = require("next/dist/shared/lib/router/utils/format-next-pathname-info.js");
- /***/ }),
- /***/ 23938:
- /***/ ((module) => {
- "use strict";
- module.exports = require("next/dist/shared/lib/router/utils/format-url.js");
- /***/ }),
- /***/ 29565:
- /***/ ((module) => {
- "use strict";
- module.exports = require("next/dist/shared/lib/router/utils/get-asset-path-from-route.js");
- /***/ }),
- /***/ 35789:
- /***/ ((module) => {
- "use strict";
- module.exports = require("next/dist/shared/lib/router/utils/get-next-pathname-info.js");
- /***/ }),
- /***/ 1897:
- /***/ ((module) => {
- "use strict";
- module.exports = require("next/dist/shared/lib/router/utils/is-bot.js");
- /***/ }),
- /***/ 1428:
- /***/ ((module) => {
- "use strict";
- module.exports = require("next/dist/shared/lib/router/utils/is-dynamic.js");
- /***/ }),
- /***/ 28854:
- /***/ ((module) => {
- "use strict";
- module.exports = require("next/dist/shared/lib/router/utils/parse-path.js");
- /***/ }),
- /***/ 91292:
- /***/ ((module) => {
- "use strict";
- module.exports = require("next/dist/shared/lib/router/utils/parse-relative-url.js");
- /***/ }),
- /***/ 34567:
- /***/ ((module) => {
- "use strict";
- module.exports = require("next/dist/shared/lib/router/utils/path-has-prefix.js");
- /***/ }),
- /***/ 80979:
- /***/ ((module) => {
- "use strict";
- module.exports = require("next/dist/shared/lib/router/utils/querystring.js");
- /***/ }),
- /***/ 93297:
- /***/ ((module) => {
- "use strict";
- module.exports = require("next/dist/shared/lib/router/utils/remove-trailing-slash.js");
- /***/ }),
- /***/ 36052:
- /***/ ((module) => {
- "use strict";
- module.exports = require("next/dist/shared/lib/router/utils/resolve-rewrites.js");
- /***/ }),
- /***/ 84226:
- /***/ ((module) => {
- "use strict";
- module.exports = require("next/dist/shared/lib/router/utils/route-matcher.js");
- /***/ }),
- /***/ 95052:
- /***/ ((module) => {
- "use strict";
- module.exports = require("next/dist/shared/lib/router/utils/route-regex.js");
- /***/ }),
- /***/ 59232:
- /***/ ((module) => {
- "use strict";
- module.exports = require("next/dist/shared/lib/utils.js");
- /***/ }),
- /***/ 71853:
- /***/ ((module) => {
- "use strict";
- module.exports = require("next/router");
- /***/ }),
- /***/ 16689:
- /***/ ((module) => {
- "use strict";
- module.exports = require("react");
- /***/ }),
- /***/ 20997:
- /***/ ((module) => {
- "use strict";
- module.exports = require("react/jsx-runtime");
- /***/ }),
- /***/ 52648:
- /***/ ((module) => {
- "use strict";
- module.exports = require("refresh-fetch");
- /***/ }),
- /***/ 57964:
- /***/ ((module) => {
- "use strict";
- module.exports = import("@milkdown/core");;
- /***/ }),
- /***/ 42154:
- /***/ ((module) => {
- "use strict";
- module.exports = import("@milkdown/preset-commonmark");;
- /***/ }),
- /***/ 76915:
- /***/ ((module) => {
- "use strict";
- module.exports = import("@milkdown/react");;
- /***/ }),
- /***/ 64744:
- /***/ ((module) => {
- "use strict";
- module.exports = import("@milkdown/utils");;
- /***/ }),
- /***/ 11601:
- /***/ ((module) => {
- "use strict";
- module.exports = import("@radix-ui/react-checkbox");;
- /***/ }),
- /***/ 77715:
- /***/ ((module) => {
- "use strict";
- module.exports = import("@radix-ui/react-dialog");;
- /***/ }),
- /***/ 4086:
- /***/ ((module) => {
- "use strict";
- module.exports = import("@radix-ui/react-radio-group");;
- /***/ }),
- /***/ 66704:
- /***/ ((module) => {
- "use strict";
- module.exports = import("@radix-ui/react-tooltip");;
- /***/ }),
- /***/ 28560:
- /***/ ((module) => {
- "use strict";
- module.exports = import("@radix-ui/react-visually-hidden");;
- /***/ }),
- /***/ 88813:
- /***/ ((module) => {
- "use strict";
- module.exports = import("firebase/compat/analytics");;
- /***/ }),
- /***/ 33773:
- /***/ ((module) => {
- "use strict";
- module.exports = import("firebase/compat/app");;
- /***/ }),
- /***/ 69915:
- /***/ ((module) => {
- "use strict";
- module.exports = import("js-cookie");;
- /***/ }),
- /***/ 45641:
- /***/ ((module) => {
- "use strict";
- module.exports = import("react-hook-form");;
- /***/ }),
- /***/ 3590:
- /***/ ((module) => {
- "use strict";
- module.exports = import("react-toastify");;
- /***/ }),
- /***/ 15941:
- /***/ ((module) => {
- "use strict";
- module.exports = import("swr");;
- /***/ }),
- /***/ 79847:
- /***/ ((module) => {
- "use strict";
- module.exports = import("swr/immutable");;
- /***/ }),
- /***/ 63477:
- /***/ ((module) => {
- "use strict";
- module.exports = require("querystring");
- /***/ })
- };
- ;
- // load runtime
- var __webpack_require__ = require("../../webpack-runtime.js");
- __webpack_require__.C(exports);
- var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId))
- var __webpack_exports__ = __webpack_require__.X(0, [11497,79165,7477,96270,24709,57933,61239,25869,50497,76410,79717,13830,37883,22197,12951,91308,42752,37013,87574], () => (__webpack_exec__(51809)));
- module.exports = __webpack_exports__;
- })();
- //# sourceMappingURL=[slug].js.map
|